package com.cloud.rou.im.client.msg;

import com.cloud.rou.im.client.statemachine.StateMachineContext;

/**
 * <p></p>
 *
 * @author GaoShuangWen
 * @since 2019-11-23 14:23
 */
public class ExecutorAggregation {

    private final ChatMessageQueueExecutor chatMessageQueueExecutor;

    private final CheckAckProcessor checkAckProcessor;


    public ExecutorAggregation() {
        chatMessageQueueExecutor = ChatMessageQueueExecutor.instance();
        checkAckProcessor = CheckAckProcessor.instance();
    }
    public void send(StateMachineContext context){
        chatMessageQueueExecutor.add(context);
        checkAckProcessor.add(context);
    }
    public void removeAck(StateMachineContext context){
        checkAckProcessor.remove(context);
    }
}
